package com.ynsj.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ynsj.domain.SysPrivilege;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

public interface SysPrivilegeService extends IService<SysPrivilege>{

    Page<SysPrivilege> findPrivilegePage(Page<SysPrivilege> privilegePage);

    boolean addPrivilege(SysPrivilege sysPrivilege);

    boolean updatePrivilege(SysPrivilege sysPrivilege);

    boolean deletePrivilege(String id);

    /**
     * 获取该菜单下该角色的权限数据
     * @param roleId
     * @param menuId
     * @return
     */
    List<SysPrivilege> getAllSysPrivileges(Long roleId, Long menuId);
}
